The need for efficiently storing digital data has increased significantly with the increased digitization of various kinds of data such as image data and audio data. While data storage apparatuses keep increasing their capacity and density to keep pace with technical advances, various techniques have also been introduced for compressing data when processing digital signals.
For example, when an image including 640.times.480 pixels, each pixel having 8 bits for each RGB, is recorded or reproduced at 30 images per second, approximately 220 MB of data is generated per second. To store two hours worth of such data, a storage capacity of approximately 200 GB is necessary. This huge amount of data can be compressed and transferred at a transfer rate of 4-5 Mbps and stored in a device having several GB of storage capacity. However, once the data is compressed at a compression ratio of nearly 1/100 as above, the original data is not restored completely when the compressed data is expanded. As a result, the compression processing deteriorates the image quality. Generally, the higher the compression ratio, the worse the image quality. To solve this problem, a technique has been proposed that allocates a greater amount of data to images involving many motions that readily cause quality deterioration and a smaller amount of data to images involving less motions. This technique can suppress the deterioration of the image quality by varying the amount of data allocated according to the image type; that is, by varying the compression ratio according to the image type.
Another problem caused by the data compression will now be explained. An "off-servo" error sometimes occurs when a portable disk device is subject to vibrations or an impact during use. Various countermeasures have been taken to solve this problem, such as providing an anti-vibration mechanism and improving servo characteristics. However, these countermeasures alone cannot prevent the off-servo error caused by a large impact or the like, thereby making the recording/reproduction impossible. To solve the above problem, Japanese Laid-open Patent Application No. 103079/1992 (Tokukaibei No. 4-103079) discloses an apparatus with improved vibration resistance that stores the compressed data into a buffer memory first, and then onto the disk. In the following, the arrangement and operation of the above conventional apparatus will be explained with reference to the accompanying drawings.
FIG. 7 is a block diagram depicting an arrangement of a conventional compressed data storage apparatus. When data is recorded into a disk device 104, an input signal is converted into a digital signal by an A/D converter 107 and sent to a compressing/expanding circuit 112. When the data is reproduced from the disk device 104, the digital signal is converted into an analog signal by a D/A converter 113 through the compressing/expanding circuit 112. The compressing/expanding circuit 112 is a circuit for compressing or expanding the data.
In the following, the compression processing related to the present invention will be explained. First, the data inputted into the compressing/expanding circuit 112 is compressed. Various compressing methods have been proposed, and when the subject data is image data or audio data, a human's visual or audio capabilities are exploited to attain a high compression ratio. Consequently, the input data is compressed at a compression ratio on the order of 1/10. The data compressed by the compressing/expanding circuit 112 is then sent to a buffer memory 102 through a memory controller 103 and stored temporarily therein. The memory controller 103 is a circuit for controlling the flow of the data through the compressing/expanding circuit 112, buffer memory 102, and disk device 104. More specifically, the memory controller 103 manages the addresses of the data in the buffer memory 102 which are transferred from the compressing/expanding circuit 112, and the addresses of the data transferred to the disk device 104 from the buffer memory 102. Also, the memory controller 103 detects an available capacity of the buffer memory 102 based on these addresses. The disk device 104 is a device for storing the data; for example, an optical disk device and a hard disk device. Both of these examples control an optical pick-up or a magnetic head to determine its position precisely to within about a micron. Therefore, if considerable vibrations or impact is given onto the device, the optical pick-up or magnetic head is displaced from the original position, thereby making the recording/reproduction impossible.
Next, the operation of the conventional compression data storage apparatus will be explained. The change of the available capacity of the buffer memory 102 over time is illustrated in FIG. 8. The available capacity of the buffer memory 102 referred herein means the amount of the memory capacity that remains unused, and is in effect, the difference between the full capacity of the buffer memory 102 and the amount of data remaining in the buffer memory 102 and not transferred to the disk device 104. Thus, when the data is transferred to the buffer memory 102 from the compressing/expanding circuit 112, the available capacity of the buffer memory 102 decreases, and when the data is transferred to the disk device 104 from the buffer memory 102, the available capacity of the buffer memory 102 increases. In FIG. 8, assume that the compressing/expanding circuit 112 starts to compress the data at a time 0. Therefore, the buffer memory 102 is empty at the time 0; in other words, a full capacity of the buffer memory 102 is available. Since the data compressed by the compressing/expanding circuit 112 is transferred to the buffer memory 102 at a constant transfer rate, the available capacity of the buffer memory 102 keeps decreasing over time. In the meantime, the available capacity of the buffer memory 102 drops below a first predetermined value TH1 at a time T1, and a system controller 105 is so notified by the memory controller 103. Upon receipt of the notification, the system controller 105 issues two commands: one is a command to the memory controller 103 to start the data transfer from the buffer memory 102 to the disk device 104, and the other is a command to the disk device 104 to start writing data onto the disk. Because the data transfer rate from the buffer memory 102 to the disk device 104 is set higher than the data transfer rate from the compressing/expanding circuit 112 to the buffer memory 102, the amount of the compressed data stored temporarily in the buffer memory 102 starts to decrease over time, and hence the available capacity of the buffer memory 102 starts to increase. In the meantime, the available capacity of the buffer memory 102 exceeds a second predetermined value TH2 at a time T2, and the system controller 105 is so notified by the memory controller 103. Upon receipt of the notification, the system controller 105 issues two commands: one is a command to the memory controller 103 to stop the data transfer from the buffer memory 102 to the disk device 104, and the other is a command to the disk device 104 to stop writing data onto the disk. In normal operation, the cycle of writing data onto the disk device 104 when the available capacity of the buffer memory 102 drops below TH1 and not writing data onto the disk when the available capacity of the buffer memory 102 exceeds TH2 is repeated hereinafter. Assume that an impact is given onto the disk device 104 at a time T3, and the disk device 104 becomes unable to write data and takes a time T5 to be restored to the data writable state. Then, the available capacity of the buffer memory 102 starts to decrease over time and drops below the first predetermined value TH1 at a time T4, at which the disk device 104 has not yet been restored to the data writable state. Thus, the system controller 105 does not start the data transfer from the buffer memory 102 to the disk device 104, and the available capacity of the buffer memory 102 keeps decreasing. In the meantime, the system controller 105 detects that the disk device 104 has been restored to the data writable state at T5, and issues a command to the memory controller 103 to start the data transfer from the buffer memory 102 to the disk device 104, whereupon available capacity of the buffer memory 102 starts to increase. Hereinafter, the normal operation is carried out repetitively.
As explained above, the conventional compressed data storage apparatus stores the data into the buffer memory 102 temporarily. According to this arrangement, in the event that the disk device 104 becomes unable to write the data temporarily, the compressed data storage apparatus can write the data onto the disk device 104 correctly without missing any data only if the disk device 104 is restored to the data writable state before the buffer memory 102 stores the data to its full capacity (available capacity=0). Consequently, this arrangement can improve the vibration resistance of the compressed data storage apparatus.
To realize the above operation, an apparatus only has to satisfy two conditions as follows:
(1) the apparatus includes a buffer memory; and PA1 (2) a data transfer rate from the buffer memory to the disk device is higher than a data transfer rate from the input end to the buffer memory.
Note that the apparatus can readily satisfy these conditions only by including a compressing circuit somewhere in a path between the input end and buffer memory, because this can decrease the data transfer rate from the input end to the buffer memory. In case of the aforementioned motion image data, the data transfer rate can be reduced from 220 Mbps to 4 Mbps. Therefore, the data transfer rate to the disk device should be at least 220 Mbps without the compression, but providing the compressing circuit somewhere in the above path can ease the data transfer rate condition to approximately 4 Mbps.
As explained above, the prior art readily realizes an excellent vibration-resistant apparatus by combining the buffer memory and the compressing circuit.
However, when the conventional apparatus is used for data with a high data transfer rate, the capacity of the buffer memory has to be increased. For example, in case of the motion image data, if the disk device takes 5 seconds to return from the damage caused by an impact, a buffer memory of as large as 4 Mbps.times.5 s=20 Mb is necessary. Therefore, when data with a high data transfer rate is handled, the capacity of the buffer memory increases and so does the cost of the apparatus.